load("@io_bazel_rules_kotlin//kotlin:jvm.bzl", "kt_jvm_library")

java_library(
    name = "fuzzed_data_provider",
    srcs = [
        "FuzzedDataProviderImpl.java",
    ],
    visibility = [
        "//agent/src/main/java/com/code_intelligence/jazzer/replay:__pkg__",
        "//agent/src/test/java/com/code_intelligence/jazzer/runtime:__pkg__",
    ],
    deps = [
        "//agent/src/main/java/com/code_intelligence/jazzer/api",
    ],
)

java_library(
    name = "signal_handler",
    srcs = ["SignalHandler.java"],
)

kt_jvm_library(
    name = "runtime",
    srcs = [
        "CoverageMap.java",
        "ExceptionUtils.kt",
        "HardToCatchError.java",
        "JazzerInternal.java",
        "ManifestUtils.kt",
        "NativeLibHooks.java",
        "RecordingFuzzedDataProvider.java",
        "TraceCmpHooks.java",
        "TraceDataFlowNativeCallbacks.java",
        "TraceDivHooks.java",
        "TraceIndirHooks.java",
    ],
    visibility = ["//visibility:public"],
    runtime_deps = [
        "//agent/src/main/java/com/code_intelligence/jazzer/autofuzz",
    ],
    deps = [
        ":fuzzed_data_provider",
        ":signal_handler",
        "//agent/src/main/java/com/code_intelligence/jazzer/api",
        "//agent/src/main/java/com/code_intelligence/jazzer/utils",
    ],
)
